Platform Explorer / Nuxeo Platform 2021.63

Extension point restlets

Documentation

This extension point lets you contribute new Restlets: ie, new REST API executor. Sample contribution: /{repo}/{docid}/pluginUpload

Contribution Descriptors

  • Class: org.nuxeo.ecm.platform.ui.web.restAPI.service.RestletPluginDescriptor

Existing Contributions

Contributions are presented in the same order as the registration order on this extension point. This order is displayed before the contribution name, in brackets.

  • nuxeo-diff-jsf-2021.63.8.jar /OSGI-INF/content-diff-restAPI-contrib.xml
    <extension point="restlets" target="org.nuxeo.ecm.platform.ui.web.restAPI.service.PluggableRestletService">
    
        <documentation>
          GET
          /nuxeo/restAPI/contentDiff/{repo}/{leftDocId}/{rightDocId}/{fieldXPath}/{subPath}?conversionType=(conversionType)&amp;locale={locale}
        </documentation>
    
        <restletPlugin class="org.nuxeo.ecm.diff.content.restlet.ContentDiffRestlet" enabled="true" name="contentDiff" useSeam="false">
          <urlPatterns>
            <urlPattern>/contentDiff/{repo}/{leftDocId}/{rightDocId}/{fieldXPath}/
            </urlPattern>
            <urlPattern>/contentDiff/{repo}/{leftDocId}/{rightDocId}/{fieldXPath}/{subPath}
            </urlPattern>
          </urlPatterns>
        </restletPlugin>
      </extension>
  • nuxeo-platform-ui-web-2021.63.8.jar /OSGI-INF/restAPI-contrib.xml
    <extension point="restlets" target="org.nuxeo.ecm.platform.ui.web.restAPI.service.PluggableRestletService">
    
        <documentation>
          Create a File document via upload
          POST /nuxeo/restAPI/{repoId}/{docId}/{filename}/upload
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.UploadRestlet" enabled="true" name="upload" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{docid}/{filename}/upload</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          Restlet for uploading a file via the Plugin (linked to FileManager)
          (ie create a document from a file)
          POST /nuxeo/restAPI/{repoId}/{docId}/pluginUpload/{path}
          POST /nuxeo/restAPI/{repoId}/{docId}/createFromFile/{path}
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.PluginUploadRestlet" enabled="true" name="pluginUpload" useConversation="false" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{docid}/pluginUpload</urlPattern>
            <urlPattern>/{repo}/{docid}/createFromFile</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          Simple restlet to browse content
          GET /nuxeo/restAPI/browse
          GET /nuxeo/restAPI/{repoId}/browse
          GET /nuxeo/restAPI/{repoId}/{docId}/browse
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.BrowseRestlet" enabled="true" name="browse" useSeam="false">
          <urlPatterns>
            <urlPattern>/browse</urlPattern>
            <urlPattern>/{repo}/browse</urlPattern>
            <urlPattern>/{repo}/{docid}/browse</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          GET /nuxeo/restAPI/{repoId}/{docId}/export
          =&gt; export a document and possibly associated tree
    
          GET /nuxeo/restAPI/{repoId}/{docId}/exportSingle
          =&gt; export a single document
    
          GET /nuxeo/restAPI/{repoId}/{docId}/exportTree
          =&gt; export a document tree
    
          Associated GET parameters are :
          - format : xml/zip
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.ExportRestlet" enabled="true" name="export" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{docid}/export</urlPattern>
            <urlPattern>/{repo}/{docid}/exportSingle</urlPattern>
            <urlPattern>/{repo}/{docid}/exportTree</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          Allows lock manipulation via Restlet API:
          GET /nuxeo/restAPI/{repoId}/{docId}/Locking/lock
          GET /nuxeo/restAPI/{repoId}/{docId}/Locking/unlock
          GET /nuxeo/restAPI/{repoId}/{docId}/Locking/status
          GET /nuxeo/restAPI/{repoId}/{docId}/Locking/state
          LOCK /nuxeo/restAPI/{repoId}/{docId}/Locking
          UNLOCK /nuxeo/restAPI/{repoId}/{docId}/Locking
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.LockingRestlet" enabled="true" name="locking" useConversation="false" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{docid}/Locking</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          GET /nuxeo/restAPI/{repoId}/{docId}/downloadFile
          or equivalently with optional query parameters:
          GET /nuxeo/restAPI/{repoId}/{docId}/downloadFile?schema=file&amp;blobField=content&amp;filenameField=filename
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.DownloadFileRestlet" enabled="true" name="downloadFileRestlet" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{docid}/downloadFile</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          Upload a file in an existing document
          POST /nuxeo/restAPI/{repo}/{docid}/{filename}/uploadFile
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.UploadFileRestlet" enabled="true" name="uploadFileRestlet" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{docid}/{filename}/uploadFile</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          GET /nuxeo/restAPI/{repo}/{parentdocid}/createDocument
          or equivalently with optional query paramaters:
          GET /nuxeo/restAPI/{repo}/{parentdocid}/createDocument?docType=File
          or
          POST /nuxeo/restAPI/{repo}/{parentdocid}/createDocument
          with arguments with initial values of the documents fields as string valued properties
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.CreateDocumentRestlet" enabled="true" name="createDocumentRestlet" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{parentdocid}/createDocument</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          Allows deleting documents via Restlet API:
          GET /nuxeo/restAPI/{repoId}/{docId}/deleteDocumentRestlet
          GET /nuxeo/restAPI/{repoId}/{docId}/delete
          GET /nuxeo/restAPI/{repoId}/deleteDocumentByPath?path=/default-domain/workspaces/doc1
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.DeleteDocumentRestlet" enabled="true" name="deleteDocumentRestlet" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{docid}/deleteDocumentRestlet</urlPattern>
            <urlPattern>/{repo}/{docid}/delete</urlPattern>
            <urlPattern>/{repo}/deleteDocumentByPath</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          Allows to update document properties via Restlet API:
          GET /nuxeo/restAPI/{repoId}/{docId}/updateDocumentRestlet?prop1=value1
          GET /nuxeo/restAPI/{repoId}/{docId}/update?prop1=value1
          example : http://127.0.0.1:8080/nuxeo/restAPI/default/1fee4b3e-8b8e-494e-b0a5-eef5113fb5a7/updateDocumentRestlet?dublincore:description=No%20comment
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.UpdateDocumentRestlet" enabled="true" name="updateDocumentRestlet" useSeam="false">
          <urlPatterns>
            <urlPattern>/{repo}/{docid}/updateDocumentRestlet</urlPattern>
            <urlPattern>/{repo}/{docid}/update</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          GET /nuxeo/restAPI/creationContainerList
          or equivalently with optional query paramaters (where docType is the
          type of the document to create):
          GET /nuxeo/restAPI/creationContainerList?docType=File
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.CreationContainerListRestlet" enabled="true" name="creationFolderListRestlet" useSeam="false">
          <urlPatterns>
            <urlPattern>/creationContainerList</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          GET /nuxeo/restAPI/opensearch?q=keywords
    
          Perform a document search on the ecm:fulltext index and return the
          results as a RSS 2.0 file with opensearch.org metadata
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.OpenSearchRestlet" enabled="true" name="openSearchRestlet" useSeam="false">
          <urlPatterns>
            <urlPattern>/opensearch</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          GET /nuxeo/restAPI/directoryCacheInvalidate
          GET /nuxeo/restAPI/directoryCacheInvalidate?directory=userDirectory&amp;directory=groupDirectory
    
          Invalidate the cache of the requested directories or of all directories if not directory name is given as parameter.
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.DirectoryCacheRestlet" enabled="true" name="directoryCache" useSeam="false">
          <urlPatterns>
            <urlPattern>/directoryCacheInvalidate</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
        <documentation>
          GET /nuxeo/restAPI/systemLog?token=1234&amp;level=INFO&amp;message=something
    
          Log something in the system logs of the server. The token has to match
          the system property org.nuxeo.systemlog.token.
        </documentation>
        <restletPlugin class="org.nuxeo.ecm.platform.ui.web.restAPI.SystemLogRestlet" enabled="true" name="systemLog" useSeam="false">
          <urlPatterns>
            <urlPattern>/systemLog</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
      </extension>
  • nuxeo-platform-webapp-base-2021.63.8.jar /OSGI-INF/restAPI-contrib.xml
    <extension point="restlets" target="org.nuxeo.ecm.platform.ui.web.restAPI.service.PluggableRestletService">
    
        <restletPlugin class="org.nuxeo.ecm.webapp.seam.NuxeoSeamHotReloadRestTrigger" enabled="true" name="seamReloadTrigger" useSeam="false">
          <urlPatterns>
            <urlPattern>/seamReload</urlPattern>
          </urlPatterns>
        </restletPlugin>
    
      </extension>
  • nuxeo-preview-jsf-2021.63.8.jar /OSGI-INF/restAPI-contrib.xml
    <extension point="restlets" target="org.nuxeo.ecm.platform.ui.web.restAPI.service.PluggableRestletService">
    
        <documentation>
          GET /nuxeo/restAPI/preview/{repoId}/{docId}/{fieldPath}?subPath=(subPath)
        </documentation>
    
        <restletPlugin class="org.nuxeo.ecm.platform.preview.restlet.PreviewRestlet" enabled="true" name="preview" useSeam="false">
          <urlPatterns>
            <urlPattern>/preview/{repo}/{docid}/{fieldPath}/{subPath}</urlPattern>
            <urlPattern>/preview/{repo}/{docid}/{fieldPath}/</urlPattern>
          </urlPatterns>
        </restletPlugin>
      </extension>